import { viteBundler } from '@vuepress/bundler-vite'
// import { defaultTheme } from '@vuepress/theme-default'
import { hopeTheme } from "vuepress-theme-hope";
import { HeadConfig, defineUserConfig } from 'vuepress'
import container from './config/container'

export default defineUserConfig({
    bundler: viteBundler({
        viteOptions: {
            build: {
                // outDir: "dist"
            },
        }
    }),
    // theme: defaultTheme({
    //     logo: "logo.svg",
    //     colorMode: "light",
    //     navbar: [
    //         { text: '主页', link: '/README.md' },
    //         { text: '组件', link: '/components/guide.md' },
    //     ],
    //     sidebar: [{
    //         text: '组件',
    //         prefix: '/components/',
    //         link: '/components/',
    //         children: [
    //             // SidebarItem
    //             {
    //                 text: '按钮',
    //                 link: 'button.md'
    //             },
    //             // 字符串 - 页面文件路径
    //             'guide.md', // 解析为 `/foo/bar.md`
    //         ],
    //     }],
    // }),
    theme: hopeTheme({
        logo: "logo.svg",
        darkmode: "disable",
        breadcrumb: false,
        pageInfo: false,
        hotReload: true,
        lastUpdated: false,
        contributors: false,
        plugins: {
            prismjs: {
                // 你想要使用的主题
                theme: "one-light",

                // // 你想要使用的主题
                // themes: {
                //     light: "one-light",
                //     dark: "one-dark",
                // },
            },
        },
    }),
    // head: [{
    //     link: { rel: "stylesheet", href: "index.scss" }
    // }],
    // head: ['link', { rel: "stylesheet", href: "index.scss" } as unknown] as HeadConfig[],
    plugins: [container],
})
